package py.com.alfa.escriba.web.services;

import java.util.List;

import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;

import py.com.alfa.escriba.exception.ServiceException;
import py.com.alfa.escriba.persistence.dto.ControlesDTO;
import py.com.alfa.escriba.persistence.dto.ControlesEscriturasDTO;
import py.com.alfa.escriba.persistence.dto.ControlesFormulariosInfoDTO;
import py.com.alfa.escriba.persistence.dto.ControlesInfoDTO;
import py.com.alfa.escriba.persistence.dto.ControlestextoDTO;
import py.com.alfa.escriba.persistence.dto.query.ControlesQueryDTO;
import py.com.alfa.escriba.persistence.dto.query.ControlesRequestDTO;
import py.com.alfa.escriba.web.interceptor.InvocationContext;

public interface ControlesService {
  List<ControlesDTO> listControles(InvocationContext ic) throws ServiceException;
  ControlesInfoDTO getControles(Long id, InvocationContext ic) throws ServiceException;
  void deleteControles(Long id, InvocationContext ic) throws ServiceException;
  @Transactional(value="transactionManager", rollbackFor={ServiceException.class},propagation=Propagation.REQUIRED)
  ControlesInfoDTO updateControles(Long id, ControlesInfoDTO dto, InvocationContext ic) throws ServiceException;
  @Transactional(value="transactionManager", rollbackFor={ServiceException.class},propagation=Propagation.REQUIRED)
  ControlesInfoDTO createControles(ControlesInfoDTO dto, InvocationContext ic) throws ServiceException;
  List<ControlesRequestDTO> listRequestControles(ControlesQueryDTO dto,InvocationContext ic) throws ServiceException;
  ControlesFormulariosInfoDTO getControlesFormulariosById(Long id, InvocationContext ic) throws ServiceException;
  List<ControlesFormulariosInfoDTO> getControlesFormulariosByIdControl(Long idControl, InvocationContext ic) throws ServiceException;
  @Transactional(value="transactionManager", rollbackFor={ServiceException.class},propagation=Propagation.REQUIRED)
  ControlesInfoDTO updateControlesFormularios(Long id, ControlesInfoDTO dto, InvocationContext ic) throws ServiceException;
  List<ControlesEscriturasDTO> listControlesEscrituraByIdControl(Long idControl,InvocationContext ic) throws ServiceException;
  ControlesEscriturasDTO getControlesEscritura(Long id, InvocationContext ic) throws ServiceException;
  @Transactional(value="transactionManager", rollbackFor={ServiceException.class},propagation=Propagation.REQUIRED)
  ControlesInfoDTO updateControlesEscritura(Long idControl, ControlesInfoDTO dto, InvocationContext ic) throws ServiceException;
  ControlestextoDTO getControlesTextoByIdControl(Long idControl,InvocationContext ic) throws ServiceException;
  ControlestextoDTO getControlesTexto(Long id, InvocationContext ic) throws ServiceException;
  @Transactional(value="transactionManager", rollbackFor={ServiceException.class},propagation=Propagation.REQUIRED)
  ControlesInfoDTO updateControlesTexto(Long idControl, ControlesInfoDTO dto, InvocationContext ic) throws ServiceException;
}